package com.itheima.controller;

import com.itheima.domain.Employee;
import com.itheima.service.EmployeeService;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import java.util.List;

/**
 * @author itheima
 * @since 2021-10-22
 */
public class AppController {
    public static void main(String[] args) {
        ApplicationContext ctx = new ClassPathXmlApplicationContext("applicationContext.xml");
        EmployeeService employeeService = (EmployeeService) ctx.getBean("employeeService");
        List<Employee> all = employeeService.getBySalaryAndSex();

        System.out.println(all);
    }
}
